homeController.$inject = ['$scope', 'merchantService']

function homeController($scope, merchantService) {
    $scope.merchantList = [];
    merchantService.getAllMerchants().then(
        function(response) {
            if (response.data.result) {
                $scope.merchantList = response.data.data;
            }
        },
        function(err) {
            console.log(err.data);
        }
    );
}

module.exports = homeController;